//index.js
const EventEmitter = require('../../common/EventEmitter');
const User = require('../../common/User');
const config = require('../../config/config');
const requester = require('../../common/Requester');
const util = require('../../common/util');

Page({
    data: {
        userInfo: {},
    },
    onLoad: function (param) {
        let me = this;
        util.getSystemInfo();
        // 初始化用户登录数据等,初始化完毕则请求数据，否则弹出失败页面。
        User.checkSession((res) => {
            me.initData();
        });
    },

    onShow: function (param) {

    },
    onPullDownRefresh: function () {
        this.setData({
            isRefreshing: true
        });
    },
    onPullDownStop: function () {
        wx.stopPullDownRefresh();
        this.setData({
            isRefreshing: false
        });
    },
    onReachBottom: function () {
        this.getData(true);
    },
    initData: function () {

    },
    getData: function (isLoadMore) {

    },
    updateData: function () {

    },
    onShareAppMessage: function (res) {

    }
});
